import * as React from "react";
import style from "./style.module.css";
import { Link } from "react-router-dom";
import { ICompany } from "../../types";
import * as Enum from "../../assets/enum";

interface Props {
  company: ICompany | undefined;
}

export default function CompanyIntroduce(props: Props) {
  return (
    <Link to={"/company/detaile/"+props.company?._id} className={style.jobcompany}>
      <div className={style.companylogo}>
        <img src={props.company?.logo} alt="" className={style.compantlogo} />
      </div>
      <div className={style.infoprimary}>
        <div className={style.companyShortName}>
          {props.company?.companyShortName}
        </div>
        <div className={style.companyFullName}>{props.company?.companyFullName}</div>
        <div className={style.gray}>
          {props.company?.industryField}
          <em className={style.vline}></em>
          {Enum.toFinance(props.company?.financeStage)}
          <em className={style.vline}></em>
          {Enum.toSize(props.company?.companySize)}
        </div>
      </div>
    </Link>
  );
}
